#define _CRT_SECURE_NO_WARNINGS
#include <string.h>
#include <vector>
#include <iostream>
using namespace std;


    int countSeniors(vector<string>& details) {
        int n = 0;
        vector<string>::iterator it = details.begin();
        while (it != details.end())
        {
            if ((*it)[11] > '6')
            {
                cout << (*it)[11] << endl;
                n++;

            }
            else if ((*it)[11] == '6' && (*it)[12] != '0')
            {
                n++;
            }
            it++;
        }
        return n;
    }
int main()
{
    vector<string> detail = {"7868190130M7522", "5303914400F9211", "9273338290F4010"};

    cout << countSeniors(detail) << endl;

	return 0;
}